[title sub="Written by Steve Jarvis, Sponsored by Arvixe hosting"]Composr Supplementary: Set Up Short URLs in Composr[/title]

[media width="150" description="Zone Code Name" float="right"]data_custom/images/docs/sup_set_up_short_urls_in_composr/933b938b372c8052e33f15462f109f03.png[/media]
Most Website users expect easy to read website URLs which help a great deal with Search Engine Optimisation so this 'How To' deals with how to set up the Short URLs when using Composr. Short URLs are easier to remember and follow than having code numbers for pages. There are two options for short URLs built in to Composr. Whichever option you want to use requires the same initial process.

If you haven't already done so you need to log in to FTP and rename recommended.htaccess to .htaccess. If you have already made and edited a .htaccess file you will need to make sure you can combine the changes you have made in to the new .htaccess file. If you don't know exactly what you are doing I recommend asking for help from someone who does as you can break your site if you do this wrong. Once you have done this you can move on to the next step.

The first thing you need to do is log in to your website FTP and locate the

[list]
[*]Go to the set up section of your Adminzone[/*]
[*]Click Configuration[/*]
[*]Choose Site options[/*]
[*]Scroll down the advanced section[/*]
[/list]
There are two options for adding short URLs; there is normal Short URLs which will give you a URL which will look something like

[url="http://yourwebsiteurl.com/ZONEA/pg/start"]http://yourwebsiteurl.com/ZONEA/pg/start[/url]

There is also new style Short URLs which would be something like:

[url="http://yourwebsiteurl.com/ZONEA/start.htm"]http://yourwebsiteurl.com/ZONEA/start.htm[/url]

If you have renamed recommended.htaccess or plain.htaccess to .htaccess you can turn the first of these options on straight away. If you want to use the second option you will need to make some changes to the .htaccess file. I only recommend doing this if you have an idea what you are doing.

You will need to add all of your new zones before completing this process and if you add any more zones you will have to make the these changes for the new zones too before they will work.

If you do this please make sure you back up your .htaccess file before you start.  Open your .htaccess file and you need to look for the following code which will need to be edited to add your zones to the following code which is located in your .htaccess file:

<p style="padding-left: 30px"># These have a specially reduce form (wide is implied)</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/galleries/image/([^\&amp;\?]*)\.htm$ $1/index.php\?page=galleries&amp;type=image&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/galleries/video/([^\&amp;\?]*)\.htm$ $1/index.php\?page=galleries&amp;type=video&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/iotds/view/([^\&amp;\?]*)\.htm$ $1/index.php\?page=iotds&amp;type=view&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px"> # These are standard patterns</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/([^/\&amp;\?]+)/([^/\&amp;\?]*)/([^\&amp;\?]*)\.htm$ $1/index.php\?page=$2&amp;type=$3&amp;id=$4 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/([^/\&amp;\?]+)/([^/\&amp;\?]*)\.htm$ $1/index.php\?page=$2&amp;type=$3 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration)/([^/\&amp;\?]+)\.htm$ $1/index.php\?page=$2 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)/([^/\&amp;\?]*)/([^\&amp;\?]*)\.htm$ index.php\?page=$1&amp;type=$2&amp;id=$3 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)/([^/\&amp;\?]*)\.htm$ index.php\?page=$1&amp;type=$2 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)\.htm$ index.php\?page=$1 [L,QSA]</p>
The section you need to add is where ever it says

<p style="padding-left: 30px">(site|forum|adminzone|cms|collaboration)</p>
You need to add your Zone codenames to this within the code so If you are adding three new zones which we will call them Zone A, Zone B and Zone C, your new section will look something like:

<p style="padding-left: 30px">(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)</p>
This will make the new section of code look like the following:

<p style="padding-left: 30px"># These have a specially reduce form (wide is implied)</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/galleries/image/([^\&amp;\?]*)\.htm$ $1/index.php\?page=galleries&amp;type=image&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/galleries/video/([^\&amp;\?]*)\.htm$ $1/index.php\?page=galleries&amp;type=video&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/iotds/view/([^\&amp;\?]*)\.htm$ $1/index.php\?page=iotds&amp;type=view&amp;id=$2&amp;wide=1 [L,QSA]</p>
<p style="padding-left: 30px"># These are standard patterns</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/([^/\&amp;\?]+)/([^/\&amp;\?]*)/([^\&amp;\?]*)\.htm$ $1/index.php\?page=$2&amp;type=$3&amp;id=$4 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/([^/\&amp;\?]+)/([^/\&amp;\?]*)\.htm$ $1/index.php\?page=$2&amp;type=$3 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^(site|forum|adminzone|cms|collaboration|ZONEA|ZONEB|ZONEC)/([^/\&amp;\?]+)\.htm$ $1/index.php\?page=$2 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)/([^/\&amp;\?]*)/([^\&amp;\?]*)\.htm$ index.php\?page=$1&amp;type=$2&amp;id=$3 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)/([^/\&amp;\?]*)\.htm$ index.php\?page=$1&amp;type=$2 [L,QSA]</p>
<p style="padding-left: 30px">RewriteRule ^([^/\&amp;\?]+)\.htm$ index.php\?page=$1 [L,QSA]</p>
You need to make sure every zone you have is added to the code or they will no longer work. Now test your zones to make sure they work ok. If there are any issues you can rename your .htaccess file within your FTP to return to your previous state.
[box="Thank you Arvixe"]This tutorial was sponsored by [url="Arvixe hosting"]http://www.arvixe.com[/url].[/box]

{$SET,tutorial_tags,SEO,Configuration,novice}{$SET,tutorial_add_date,Jun 2013}{$SET,tutorial_summary,Most Website users expect easy to read website URLs which help a great deal with Search Engine Optimisation so this 'How To' deals with how to set up the Short …
}[block]main_tutorial_rating[/block]